package com.zmn.plat.dubbo.interfaces.extensioncategory;

import com.zmn.common.dto.VtDTO;
import com.zmn.common.dto2.ResponseDTO;
import com.zmn.plat.common.dto.extensioncategory.ExtensionServCategoryDRO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Positive;
import java.util.List;

/**
 * 推广服务分类远程服务接口
 *
 * @author linfeng
 * @version v1.0
 * @since 2020/03/30 10:31
 */
@Api(value = "推广服务分类服务", tags = {"推广服务分类"})
public interface ExtensionServCategoryListRemoteService {

    /**
     * 根据推广服务分类ID查询推广服务分类
     *
     * @param id
     *            推广服务分类ID 和 服务分类ID是一致的
     * @return
     */
    @ApiOperation(value = "根据推广服务分类ID查询推广服务分类", response = ResponseDTO.class, notes = "推广服务分类ID 和 服务分类ID是一致的", tags = {"推广服务分类"})
    ResponseDTO<ExtensionServCategoryDRO> getByExtServCategId(@NotNull(message = "Id不能为空") @Positive(message = "Id必须为大于0的正整数") @ApiParam(value = "推广服务分类ID", required = true) Integer id);

    /**
     * 列表查询:根据推广服务名称和状态查询 均可空
     *
     * @param name
     *            非必填
     * @param status
     *            非必填 如果传值：有效值 1 停用 2 启用
     * @return
     */
    @ApiOperation(value = "根据推广服务名称和状态查询", response = ResponseDTO.class, notes = "参数可空", tags = {"推广分类"})
    ResponseDTO<List<VtDTO>> listByNameAndStatus(@ApiParam(value = "名称") String name, @ApiParam(value = "状态") Integer status);

    /**
     * 根据推广服务分类ID查询关联的推广分类
     *
     * @param id
     *            推广服务分类ID 必填
     */
    @ApiOperation(value = "根据推广服务分类ID查询关联的推广分类", response = ResponseDTO.class, notes = "关联的推广分类", tags = {"关联的推广分类"})
    ResponseDTO<List<VtDTO>> listExtCategByExtServCategId(@NotNull(message = "Id不能为空") @Positive(message = "Id必须为大于0的正整数") @ApiParam(value = "推广服务分类ID", required = true) Integer id);

    /**
     * 根据推广服务分类ID和推广分类ID查询关联的后台分类二级分类
     *
     * @param extServCategId
     *            必填
     * @param extCategId
     *            必填
     * @return
     */
    @ApiOperation(value = "根据推广服务分类ID和推广分类ID查询关联的后台分类二级分类", response = ResponseDTO.class, notes = "后台分类二级分类", tags = {"后台分类二级分类"})
    ResponseDTO<List<VtDTO>> listCategoryByExtServCategIdAndExtCategId(
        @NotNull(message = "extServCategId不能为空") @Positive(message = "extServCategId必须为大于0的正整数") @ApiParam(value = "推广服务分类ID", required = true) Integer extServCategId,
        @NotNull(message = "extCategId不能为空") @Positive(message = "extCategId必须为大于0的正整数") @ApiParam(value = "推广分类ID", required = true) Integer extCategId);
}
